<?php /* Smarty version 2.6.26, created on 2011-12-21 02:53:11
         compiled from index.tpl */ ?>
<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => 'f-header.tpl', 'smarty_include_vars' => array()));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>


<div class="main">
<div class="search">
				<div class="search_left">
					<form>
						<input class="skw" name="" value="keyword..." />
						<select>
							<option value="">Categoria</option>
							<option value="">Categoria</option>
							<option value="">Categoria</option>
						</select>
						<select>
							<option value="">Categoria</option>
							<option value="">Categoria</option>
							<option value="">Categoria</option>
						</select>
						<a href="#" class="searchbtn"></a>
					</form>
				</div>
				<div class="search_right">
                    <?php $_from = $this->_tpl_vars['icoRs']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
    foreach ($_from as $this->_tpl_vars['key'] => $this->_tpl_vars['value']):
?> 
                        <div class="item">
                        <a href="#"><img src=<?php echo $this->_tpl_vars['value']['info_ico']; ?>
  alt="<?php echo $this->_tpl_vars['value']['info_name']; ?>
" title="" /></a>
                        <div class="caption">
                        <p><a href="<?php echo $this->_tpl_vars['baseUrl']; ?>
info/single?id=<?php echo $this->_tpl_vars['value']['info_id']; ?>
" title=<?php echo $this->_tpl_vars['value']['info_name']; ?>
>查看信息</a></p>
                        <p><a href="javascript:showWhere('<?php echo $this->_tpl_vars['value']['info_google_address']; ?>
',<?php echo $this->_tpl_vars['value']['info_class']; ?>
)" title=<?php echo $this->_tpl_vars['value']['info_name']; ?>
>查看地址</a></p>
                        </div>
                        </div>
                    <?php endforeach; endif; unset($_from); ?>
                </div>
			</div>

    <div class="map">
				<div class="map_main">
                    <div id="map_canvas" style=""></div>
				</div>
				<div class="map_info">
					<p>Centri Maps</p>
					<div class="map_info_s">
						<img src="<?php echo $this->_tpl_vars['baseUrl']; ?>
public/images/icon1.png" />
						<span>Centri deluxe </span>
					</div>
					<div class="map_info_s">
						<img src="<?php echo $this->_tpl_vars['baseUrl']; ?>
public/images/icon2.png" />
						<span>Centri deluxe </span>
					</div>
					<div class="map_info_s">
						<img src="<?php echo $this->_tpl_vars['baseUrl']; ?>
public/images/icon3.png" />
						<span>Centri deluxe </span>
					</div>
					<div class="map_info_s">
						<img src="<?php echo $this->_tpl_vars['baseUrl']; ?>
public/images/icon4.png" />
						<span>Centri deluxe </span>
					</div>
					<div>
						<img src="<?php echo $this->_tpl_vars['baseUrl']; ?>
public/images/smap.png" />
					</div>
				</div>
    <div class="clear"></div>

</div>


<?php echo '
<script type="text/javascript" src="http://maps.googleapis.com/maps/api/js?sensor=false"></script>
<script type="text/javascript">
  var map;
  var myOptions;
  var markers=[];
  var latlng = new google.maps.LatLng(45.476985,9.18663);
  function initialize() {
      myOptions = {
      zoom: 4,
      center: latlng,
      mapTypeId: google.maps.MapTypeId.ROADMAP
      };
      map = new google.maps.Map(document.getElementById("map_canvas"), myOptions);
  }
  
initialize();
</script>
'; ?>



<?php $_from = $this->_tpl_vars['rs']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
    foreach ($_from as $this->_tpl_vars['key'] => $this->_tpl_vars['value']):
?> 
<?php echo '
<script>
    
    var address='; ?>
"<?php echo $this->_tpl_vars['value']['info_google_address']; ?>
"<?php echo ';
    var image='; ?>
"<?php echo $this->_tpl_vars['baseUrl']; ?>
public/images/icon<?php echo $this->_tpl_vars['value']['info_class']; ?>
.png"<?php echo ';
    address=address.split(",");
    var x=address[0];
    var y=address[1];
    var point= new google.maps.LatLng(x,y);
    var marker = new google.maps.Marker({
        position: point, 
        map: map, 
        icon:image,
        title:'; ?>
"<?php echo $this->_tpl_vars['value']['info_name']; ?>
"<?php echo '
    });
    markers.push(marker);
</script>
'; ?>

<?php endforeach; endif; unset($_from); ?>
<?php echo '
<script>
var latlngbounds = new google.maps.LatLngBounds();
  for (i in markers) {
        markers[i].setMap(map);
        latlngbounds.extend(markers[i].getPosition());
}
map.fitBounds(latlngbounds); 

function showWhere(address,type){
    address=address.split(",");
    var x=address[0];
    var y=address[1];
    var image='; ?>
"<?php echo $this->_tpl_vars['baseUrl']; ?>
public/images/icon"+type+".png"<?php echo ';
    if (markers) {
        for (i in markers) {
            markers[i].setMap(null);
        }
        markers.length = 0;
    }
    var pointNew= new google.maps.LatLng(x,y);
    var markerNew= new google.maps.Marker({
        position: point, 
        map: map, 
        icon:image,
        title:'; ?>
"<?php echo $this->_tpl_vars['value']['info_name']; ?>
"<?php echo '
    });
    markers.push(markerNew);
    var latlngbounds = new google.maps.LatLngBounds();
    for (i in markers) {
        markers[i].setMap(map);
        latlngbounds.extend(markers[i].getPosition());
    }
    map.fitBounds(latlngbounds); 
}

</script>
'; ?>

</div>
<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => 'f-footer.tpl', 'smarty_include_vars' => array()));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>